package com.android.tea;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.ImageView;

import com.android.tea.util.ToastManager;

public class VersionActivity extends Activity implements OnClickListener{
	
	private ImageView btn_back;
	private Button btn_check;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.version);
		TeaEncyclopediaApp.list.add(this);
		
		initComponents();
		
	}

	private void initComponents() {
		btn_back = (ImageView)findViewById(R.id.btn_back);
		btn_back.setVisibility(View.VISIBLE);
		btn_check = (Button)findViewById(R.id.btn_check);
		btn_check.setOnClickListener(this);
		btn_back.setOnClickListener(this);
	}

	@Override
	public void onClick(View v) {
		switch (v.getId()) {
		case R.id.btn_back:
			super.onBackPressed();
			break;
		case R.id.btn_check :
			ToastManager.showToast(this, R.string.Setting_Update_Version);
			break;
		default:
			break;
		}
		
	}

}
